package com.caseeye.dao

import org.springframework.stereotype.Component
import com.caseeye.model.User
import com.caseeye.base.GenericDAO

@Component
class UserDAO extends GenericDAO[User] {

    def findByLoginId(loginId : String) : Option[User] = queryOne("loginId" -> loginId)

    def findByUserName(userName : String) : List[User] = query("userName" -> userName)
}